<%@ page language="java" pageEncoding="utf-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
${aier_doctype}
<html <s:property value="aier-html-xmlns" escape="false"/>>
<head>
<meta http-equiv="Content-Type" content="${aier_content_type}" />
<meta name="keywords" content="${aier_keyworks}" />
<meta name="description" content="${aier_description}" />
<title>${aier_title}</title>
<link rel="stylesheet" href="${aier_css_url}${aier_jqui_css}ui.css" />
<link rel="Stylesheet" href="${aier_css_url}jq/jq.css" />
<link rel="Stylesheet" href="${aier_css_url}jq/multiselect.css" />
<link rel="stylesheet" href="${aier_css_url}jc/chosen.css">
<link rel="stylesheet" href="${aier_css_url}social/module/jq-msg.css" />
<link rel="stylesheet" href="${aier_css_url}social/module/reset.css" />
<link rel="stylesheet" href="${aier_css_url}social/module/btn.css" />
<link rel="stylesheet" href="${aier_css_url}social/classes/classhomepage.css" />

<script type="text/javascript" src="${aier_js_url}j.js"></script>
<script type="text/javascript" src="${aier_js_url}b.js"></script>
<script type="text/javascript" src="${aier_js_url}${aier_jqui_js}ui.js"></script>
<script type="text/javascript" src="${aier_js_url}97/WdatePicker.js"></script>
<script type="text/javascript" src="${aier_js_url}jp/msg.js"></script>
<script type="text/javascript" src="${aier_js_url}jq/cn.js"></script>
<script type="text/javascript" src="${aier_js_url}jq/jq.js"></script>
<script type="text/javascript" src="${aier_js_url}lib/ja.js"></script>
<script type="text/javascript" src="${aier_js_url}jc/cj.js"></script>
<script type="text/javascript" src="${aier_js_url}lib/block.js"></script>
<script type="text/javascript" src="${aier_js_url}jq/multiselect.js"></script>
<script type="text/javascript" src="${aier_js_url}trantime/jquery-aier.js"></script>
<!-- 
<script type="text/javascript" src="${aier_js_url}social/classes/cminvite.js"></script> -->
</head>
<body>

	<!-- 顶栏 -->
	<s:action name="userhomecomm_homeHead" namespace="/user" executeResult="true"></s:action>

	<div class="window-content">
		<!-- 正文 -->
		<div class="wrap wrap-class-center">
		
			<s:action name="ccomm_classesHTitle" namespace="/classes" executeResult="true"></s:action>

			<!-- main -->

			<div class="wrap-main">
				<!-- 中间导航栏 -->
				<div class="wrap-main-nav">
					<ul class="float-list clearfix">
						<li><a class="class-center-tag" href="${aier_url}classes/classeshome_classHomePage.shtml?cid=${cid}">作业栏</a></li>
						<li><a class="class-center-tag" href="${aier_url}classes/classeshome_classesAlbum.shtml?cid=${cid}">班级风采</a></li>
						<li><a class="class-center-tag current" href="${aier_url}classes/classeshome_classesBoast.shtml?cid=${cid}">夸一夸</a></li>
					    <li><a class="class-center-tag last-has-border" href="${aier_url}classes/classeshome_classesPhotos.shtml?cid=${cid}">班级相册</a></li>
					</ul>
				</div>

				<!-- 信息流和侧栏 -->
				<div class="wrap-main-column clearfix">


					<!-- 信息流  -->

					<div class="wrap-main-column-stream ">

						<div class="main-column-inside">
							
							<div class="class-kuayikua">
								<div class="kuayikua-numbar">
									<div class="group"></div>
								</div>

								<div class="kuayikua-list" id = "appraise">
									
									
								</div>


							</div>
							<!-- 夸一夸结束 -->



						</div>
						<!-- end inside -->


					</div>
					
					<!-- 侧栏 -->

					<s:action name="ccomm_classesHRight" namespace="/classes" executeResult="true"></s:action>
					<!-- 侧栏结束 -->
				
				</div>

			</div>
			<!-- 返回顶部 -->
			<s:action name="userhomecomm_backToTop" namespace="/user" executeResult="true"></s:action>
			<!-- end 返回顶部 -->
		</div>
		<!-- footer copyright -->
		<s:action name="userhomecomm_homeFooter" namespace="/user" executeResult="true"></s:action>
		<!-- /footer copyright -->
	</div>


<script>
$(window).bind('scroll', function(){
	var a = $(this).scrollTop(),
		b = $(this).outerHeight();
	if ( a > 100 ) {
		$('#btt').css({'display':'block','top':a+b-200});
	} else {
		$('#btt').css('display','none');
	}
});



// 预览图和完整图切换
$('.zoom-out,.collapse-btn').click(function(){
	$(this).parents('.xxs-extend').css('display','none')
	.prev('.xxs-media-pre').css('display','block');
});
$('.zoom-in').click(function(){
	$(this).parents('.xxs-media-pre').css('display','none')
	.next('.xxs-extend').css('display','block');
});


// 封面设置
$('.cover-setting-btn').click(function(){
$(".cover-setting-box").dialog(
		{
			//背景变暗
			modal : true,
			autoOpen : false,
			show : "fade",
			hide : "fade",
			width : "340",
			height : "220",
			buttons : {
				"确定" : function() {
					var funadd = function(data1) {

					};
					exeAjax(ajaxUrl(global_url + "class_maintain_delt"
							+ global_suffix), funadd, {
						"cid" : global_cid,
						"tid" : jQuery("#teacherinfo").jqGrid(
								'getRowData', id).tid
					});
				},
				"取消" : function() {
					$(this).dialog("close");
				}
			}
		});
});

    // 夸一夸
    $(document).ready(function() {
        var fun = function(data) {
            if (data.s == 1) {
                // 刷新评语列表
                var html = "";
                if (data.appraiseList != null) {
                    for ( var i = 0; i < data.appraiseList.length; i++) {
                        var appraise = data.appraiseList[i];
                        html += '<div class="kuayikua-item"><div class="avatar"><a><img width="50" height="50" src="${get_picturl_url}small/'+appraise.headimg+'"></a></div>';
                        html += '<div class="info"><div class="info-award">';
                        html += '<span>'
                                + appraise.tname + '老师  发送给 '
                                + appraise.bname + ' 的评语<span></div>';
                        html += '<div class="info-class">'+appraise.content+'</div>';
                        html += '<div class="info-date">'+appraise.cdate.split("T")[0]+' '+appraise.cdate.split("T")[1]+'</div></div></div>';

                    }
                }
                
                $("#appraise").html(html);
                
            }
        };
        exeAjax(
                ajaxUrl("${aier_url}userjs/userhscb_searchTAppraiseList${aier_suffix}"),
                fun, {
                    "cid" : "${cid}",
                    "page":1,
                    "page_size":10
                });
    });


</script>
</body>
</html>